import Taro,
{ Component } from '@tarojs/taro'
import { View, Text } from '@tarojs/components'
// import { DNavBar, DImagesupload, DAtInpute } from '@/components'
import http from '@/api'
import sdk from '@/common/sdk'
// import './mycompany.scss'

export default class MycompanyBox extends Component {

    constructor(props) {
        super(props)
        this.state = {
            title: '建行支付成功',
        }
    }

    componentWillMount() {
        // let creatorId = ''
        // if (localStorage.getItem('userInformation')) {
        //     let { infoMyEntity = '' } = JSON.parse(localStorage.getItem('userInformation'))
        //     creatorId = infoMyEntity.imIdStatus
        // }
        // let { id } = this.$router.params
        // this.setState({
        //     id,
        //     creatorId,
        //     statusClk: creatorId === '1' ? true : false
        // })

        this.getPayParams()

    }
    getPayParams() {
        const { ORDERID } = this.$router.params
        if (ORDERID) {
            window.location.href = `http://47.114.190.170:9094/#/pages/testPay?orderId=${ORDERID}`
        }

        // http.orderIspay(this.$router.params.ORDERID).then(res => {
        //     if (this.$router.params.REMARK1 === 'topic.transCar') {
        //         Taro.redirectTo({
        //             url: `/pages/shoporders/shoporders?active=1`
        //         })
        //     } else if (this.$router.params.REMARK1 === 'topic.trans') {
        //         Taro.redirectTo({
        //             url: `/pages/consignment/consignment`
        //         })
        //     }
        // })
    }
    componentDidShow() {
        let { title } = this.state
        sdk.setTitleInfo(title)
        // if(page > 1){
        // this.getCompanyInfo(id)
        // }
    }

    render() {

        return (
            <View className="b_mycompany">

            </View>
        )
    }
}
